package com.sigmatrix.h5.entity.v2;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.sigmatrix.h5.enums.StatusEnum;


@TableName(value="_distribution_dealers_acct")
public class DisDealerAcct {
	
	@TableId(value = "_id", type = IdType.AUTO)
	private Integer id;
	
	@TableField("_basic_module_id")
	private Integer basicModuleId;
	
	@TableField("_dealer_id")
	private Integer dealerId;
	
	@TableField("_account")
	private String account;
	
	@TableField("_pwd")
	private String pwd;
	
	@TableField(value="_name")
	private String name;
	
	@TableField("_open_id")
	private String openId;
	
	@TableField("_status")
	private Short status;
	
	@TableField("_contact")
	private String contact;
	
	@TableField("_additional_contact")
	private String additionalContact;
	
	@TableField("_audit")
	private Short audit;
	
	@TableField("_remarks")
	private String remarks;
	
	@TableField("_enterprise_id")
	private Integer enterpriseId;
	
	/**
	 * CrmAcctType
	 */
	@TableField("_acct_type")
	private Short acctType;
	
	@TableField("_terminal_shop_id")
	private Integer terminalShopId;
	
	@TableField("_promotion_code")
	private String promotionCode;
	
	/**
	 * UserType
	 */
	@TableField("_user_type")
	private Short userType;
	
	@TableField("_dealers_acct_promotion_code")
	private String dealersAcctPromotionCode;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getBasicModuleId() {
		return basicModuleId;
	}

	public void setBasicModuleId(Integer basicModuleId) {
		this.basicModuleId = basicModuleId;
	}

	public Integer getDealerId() {
		return dealerId;
	}

	public void setDealerId(Integer dealerId) {
		this.dealerId = dealerId;
	}

	public String getAccount() {
		return account;
	}

	public void setAccount(String account) {
		this.account = account;
	}

	public String getPwd() {
		return pwd;
	}

	public void setPwd(String pwd) {
		this.pwd = pwd;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getOpenId() {
		return openId;
	}

	public void setOpenId(String openId) {
		this.openId = openId;
	}

	public Short getStatus() {
		return status;
	}

	public void setStatus(Short status) {
		this.status = status;
	}

	public String getContact() {
		return contact;
	}

	public void setContact(String contact) {
		this.contact = contact;
	}

	public String getAdditionalContact() {
		return additionalContact;
	}

	public void setAdditionalContact(String additionalContact) {
		this.additionalContact = additionalContact;
	}

	public Short getAudit() {
		return audit;
	}

	public void setAudit(Short audit) {
		this.audit = audit;
	}

	public String getRemarks() {
		return remarks;
	}

	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}

	public Integer getEnterpriseId() {
		return enterpriseId;
	}

	public void setEnterpriseId(Integer enterpriseId) {
		this.enterpriseId = enterpriseId;
	}

	public Short getAcctType() {
		return acctType;
	}

	public void setAcctType(Short acctType) {
		this.acctType = acctType;
	}

	public Integer getTerminalShopId() {
		return terminalShopId;
	}

	public void setTerminalShopId(Integer terminalShopId) {
		this.terminalShopId = terminalShopId;
	}

	public String getPromotionCode() {
		return promotionCode;
	}

	public void setPromotionCode(String promotionCode) {
		this.promotionCode = promotionCode;
	}

	public Short getUserType() {
		return userType;
	}

	public void setUserType(Short userType) {
		this.userType = userType;
	}

	public String getDealersAcctPromotionCode() {
		return dealersAcctPromotionCode;
	}

	public void setDealersAcctPromotionCode(String dealersAcctPromotionCode) {
		this.dealersAcctPromotionCode = dealersAcctPromotionCode;
	}

	/**
	 * 该用户是否用
	 * @return
	 */
	public boolean isEnabled() {
		if(this.status==null){
			return false;
		}
		if(this.status.intValue()==StatusEnum.STATUS_ENABLE.getId().intValue()){
			return true;
		}
		return false;
	}
	
	
}
